﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Serialization;

namespace RandomStudent.Entity
{
    [Serializable]
    public class MenuItem
    {
        private int menuId;

        public int MenuId
        {
            get { return menuId; }
            set { menuId = value; }
        }

        private string name;

        public string Name
        {
            get { return name; }
            set { name = value; }
        }

        private string text;

        public string Text
        {
            get { return text; }
            set { text = value; }
        }


    }

    [Serializable]
    public class MenuGroup
    {
        private int groupId;

        public int GroupId
        {
            get { return groupId; }
            set { groupId = value; }
        }

        private string name;

        public string Name
        {
            get { return name; }
            set { name = value; }
        }

        private string text;

        public string Text
        {
            get { return text; }
            set { text = value; }
        }

        private List<MenuGroup> menuList;

        public List<MenuGroup> GroupList
        {
            get { return menuList; }
            set { menuList = value; }
        }

        private List<MenuItem> menuItem;

        public List<MenuItem> ItemList
        {
            get { return menuItem; }
            set { menuItem = value; }
        }
    }
    [XmlRoot("Menu", Namespace = "RandomStudent.Entity", IsNullable = false)]
    public class MenuList
    {
        private List<MenuGroup> groupList;

        public List<MenuGroup> GroupList
        {
            get { return groupList; }
            set { groupList = value; }
        }

    }
}
